<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <title>忘记密码</title>
    <link rel="stylesheet" href="css/bootstrap.css">
    <link rel="stylesheet" href="css/public.css">
    <link rel="stylesheet" href="css/passe.css">

    <!--[if lt IE 9]>
      <script src="js/html5shiv.min.js"></script>
      <script src="js/respond.min.js"></script>
    <![endif]-->
    <script src="js/jquery-2.1.0.min.js"></script>
    <script src="js/bootstrap.js"></script>
    <script src="js/bootstrapValidator.js"></script>
  </head>
  <body>
  <!--header-->
  <div class="navbar navbar-default header">
      <div class="container">
          <div class="navbar-header">
              <a class="navbar-brand" href="javascript:;">欢迎来到易术网!</a>
          </div>
      </div>
  </div>
  <!--logo-->
  <div class="logoBox">
      <div class="container">
          <a href="javascript:;">
              <span class="logo"></span>
          </a>
      </div>
  </div>
  <!--main-->
  <div class="main">
      <div class="container-fluid bgColor">
          <div class="container">
              <img src="images/bg_img.png" alt=""/>

              <div class="box">
                  <div class="login-content">
                    <div class="list">
                          <ul class="list-inline nav nav-tabs " role="tablist">
                              <li role="presentation" class="active">
                                  <a href="#login"role="tab" data-toggle="tab">找回密码</a>
                              </li>
                              <li role="presentation">
                                  <a href="#register" role="tab" data-toggle="tab">重置密码</a>
                              </li>
                          </ul>

                          <div class="tab-content">
                               <div role="tabpanel" class="tab-pane active" id="login">
                                   <div class="form">
                                       <form id="forgetPwd" action="#" method="post">
                                           <div class="form-group">
                                               <div class="col-xs-12">
                                                   <div class="input-group">
                                          <span class="input-group-addon">
                                              <span class="glyphicon glyphicon-user"></span>
                                          </span>
                                                       <input type="text" id="ftusername" name="ftusername" class="form-control"  placeholder="请输入登录账号">
                                                   </div>
                                               </div>
                                           </div>

                                           <div class="form-group">
                                               <div class="col-xs-8 link">
                                                   <div class="input-group">
                                                       <span class="input-group-addon"><span class="glyphicon glyphicon-check"></span></span>
                                                       <input type="text" id="ftyanzhengma" name="ftyanzhengma" class="form-control" placeholder="请输入验证码">
                                                   </div>
                                               </div>
                                               <div class="col-xs-4 link btn_size">
                                                   <input type="submit" value="获取验证码"/>
                                               </div>
                                           </div>

                                           <div class="form-group form-actions">
                                               <div class="col-xs-12">
                                                   <button type="submit" id="ft_reset" class="btn btn-lg btn-block login_btn">重置密码</button>
                                               </div>
                                           </div>
                                       </form>
                                   </div>
                               </div>
                               <div role="tabpanel" class="tab-pane" id="register">
                                   <div class="form">
                                       <form id="resetPwd" action="#" method="post">
                                           <div class="form-group">
                                               <div class="col-xs-12">
                                                   <div class="input-group">
                                                       <span class="input-group-addon">
                                                         <span class="glyphicon glyphicon-lock"></span>
                                                      </span>
                                                       <input type="text" id="rtpassword" name="rtpassword" class="form-control" placeholder="请再次输入密码">
                                                   </div>
                                               </div>
                                           </div>
                                         <div class="form-group">
                                               <div class="col-xs-12">
                                                   <div class="input-group">
                                                       <span class="input-group-addon">
                                                         <span class="glyphicon glyphicon-lock"></span>
                                                      </span>
                                                       <input type="text" id="re_rtpassword" name="re_rtpassword" class="form-control" placeholder="请再次输入密码">
                                                   </div>
                                               </div>
                                           </div>
                                           <div class="form-group form-actions">
                                               <div class="col-xs-12">
                                                   <button type="submit" id="rt_affirm" class="btn btn-lg btn-block login_btn">确认重置</button>
                                               </div>
                                           </div>
                                       </form>
                                   </div>
                               </div>
                          </div>
                      </div>


                  </div>
              </div>
          </div>
      </div>
  </div>
  <div class="footer">
      <div class="container">
          <p class="text-center">
              Copyright © 2008-2014 Change360.cn All Rights Reserved 西安创知信息科技有限公司
          </p>
      </div>
  </div>
  <script>
      $(document).ready(function() {
          // Generate a simple captcha
          function randomNumber(min, max) {
              return Math.floor(Math.random() * (max - min + 1) + min);
          };

          $('#forgetPwd').bootstrapValidator({
//       /* live: 'disabled',*/
//        message: 'This value is not valid',
              //feedbackIcons: {
              //    valid: 'glyphicon glyphicon-ok',
              //    invalid: 'glyphicon glyphicon-remove',
              //    validating: 'glyphicon glyphicon-refresh'
              //},
              fields: {
                  ftusername: {
                      validators: {
                          notEmpty: {
                              message: '您输入的账号有误，请重新输入'
                          }
                      }
                  }
                 /* lgpassword: {
                      validators: {
                          notEmpty: {
                              message: '您输入的密码有误，请重新输入'
                          },
                          different: {
                              field: 'lgusername',
                              message: 'The password cannot be the same as lgusername'
                          }
                      }
                  }*/

              }
          });


          $('#resetPwd').bootstrapValidator({
              fields: {
                  /*reusername: {
                      validators: {
                          notEmpty: {
                              message: '您输入的账号有误，请重新输入'
                          }
                      }
                  },*/
                  rtpassword: {
                      validators: {
                          notEmpty: {
                              message: '您输入的密码不符合格式，请重新输入'
                          },
                          identical: {
                              field: 're_rtpassword',
                              message: '您输入的密码不符合格式，请重新输入'
                          }/*,
                          different: {
                              field: 'username',
                              message: '您的账户名与密码不符合'
                          }*/
                      }
                  },
                  re_rtpassword: {
                      validators: {
                          notEmpty: {
                              message: '您输入的两次密码不一致'
                          },
                          identical: {
                              field: 'rtpassword',
                              message: '您输入的两次密码不一致'
                          }/*,
                          different: {
                              field: 'username',
                              message: 'The rtpassword cannot be the same as username'
                          }*/
                      }
                  }

              }
          });
          // Validate the form manually
          $('#ft_reset').click(function() {
              $('#forgetPwd').bootstrapValidator('validate');
          });

          $('#rt_affirm').click(function() {
              $('#resetPwd').bootstrapValidator('validate');
          });
          /*$('#resetBtn').click(function() {
           $('#lg_login').data('bootstrapValidator').resetForm(true);
           });*/
      });
  </script>
  </body>
  </html>